package com.tms.domain;

import com.alibaba.fastjson.annotation.JSONField;

/**
 * 用户类
 * 所有用户都用这个类
 *
 * @author sxy
 */
public class User {

    public User() {
    }

    public User(int id, String name) {
        this.id = id;
        this.name = name;
    }

    public User(String no, String name, String email, String phone, String pwd, Workcell workcell, Position position) {
        this.no = no;
        this.name = name;
        this.email = email;
        this.phone = phone;
        this.pwd = pwd;
        this.workcell = workcell;
        this.position = position;
    }

    /**
     * 加了ID的构造方法
     *
     * @param id
     * @param no
     * @param name
     * @param email
     * @param phone
     * @param pwd
     * @param workcell
     * @param position
     */
    public User(int id, String no, String name, String email, String phone, String pwd, Workcell workcell, Position position) {
        this.id = id;
        this.no = no;
        this.name = name;
        this.email = email;
        this.phone = phone;
        this.pwd = pwd;
        this.workcell = workcell;
        this.position = position;
    }

    private int id;

    private String no;

    private String name;

    private String email;

    private String phone;

    @JSONField(serialize = false)
    private String pwd;

    private Workcell workcell;

    private Position position;

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getNo() {
        return no;
    }

    public void setNo(String no) {
        this.no = no;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getPwd() {
        return pwd;
    }

    public void setPwd(String pwd) {
        this.pwd = pwd;
    }

    public Workcell getWorkcell() {
        return workcell;
    }

    public void setWorkcell(Workcell workcell) {
        this.workcell = workcell;
    }

    public Position getPosition() {
        return position;
    }

    public void setPosition(Position position) {
        this.position = position;
    }
}